﻿using System;
using System.Collections.Generic;
using VisualWip.Core.Interfaces;

namespace VisualWip.Core
{
    public class SettingsPathComparer: IEqualityComparer<ISettingsPath>
    {
        #region Implementation of IEqualityComparer<in ISettingsPath>

        public bool Equals(ISettingsPath x, ISettingsPath y)
        {
            return StringComparer.InvariantCulture.Compare(x.Path, y.Path) == 0;
        }

        public int GetHashCode(ISettingsPath obj)
        {
            return obj.Path.GetHashCode();
        }

        #endregion
    }
}